let t = require;
let  e = module
let  o =  e.exports;
 o.default =  e.exports;

                'use strict';
                console.log("start");
                var _n24,
                    i =
                    (this && this.__extends) ||
                    ((_n24 = function n(t, e) {
                            return (_n24 =
                                Object.setPrototypeOf ||
                                ({
                                        __proto__: []
                                    }
                                    instanceof Array &&
                                    function(t, e) {
                                        t.__proto__ = e;
                                    }) ||
                                function(t, e) {
                                    for (var o in e) {
                                        Object.prototype.hasOwnProperty.call(e, o) && (t[o] = e[o]);
                                    }
                                })(t, e);
                        }),
                        function(t, e) {
                            function o() {
                                this.constructor = t;
                            }
                            _n24(t, e),
                                (t.prototype =
                                    null === e ?
                                    Object.create(e) :
                                    ((o.prototype = e.prototype), new o()));
                        }),
                    r =
                    (this && this.__decorate) ||
                    function(t, e, o, n) {
                        var i,
                            r = arguments.length,
                            a =
                            r < 3 ?
                            e :
                            null === n ?
                            (n = Object.getOwnPropertyDescriptor(e, o)) :
                            n;
                        if (
                            'object' ==
                            (typeof Reflect === 'undefined' ?
                                'undefined' :
                                typeof(Reflect)) &&
                            'function' == typeof Reflect.decorate
                        )
                            a = Reflect.decorate(t, e, o, n);
                        else
                            for (var s = t.length - 1; s >= 0; s--) {
                                (i = t[s]) &&
                                (a = (r < 3 ? i(a) : r > 3 ? i(e, o, a) : i(e, o)) || a);
                            }
                        return r > 3 && a && Object.defineProperty(e, o, a), a;
                    };
                Object.defineProperty(o, '__esModule', {
                        value: !0
                    }),
                    (o.AlertPanel = o.AlertVO = o.AlertType = void 0);
                var a,
                    s = t('UIPanel'),
                    c = t('UIViewRes'),
                    l = t('UILayer'),
                    u = t('SoundMrg'),
                    h = t('ComUtils'),
                    p = t('UIMrg'),
                    f = cc._decorator,
                    d = f.ccclass;
                f.property,
                    (function(t) {
                        (t[(t.Confirm = 0)] = 'Confirm'),
                        (t[(t.Cancel = 1)] = 'Cancel'),
                        (t[(t.ConfirmAndCancel = 2)] = 'ConfirmAndCancel');
                    })((a = o.AlertType || (o.AlertType = {})));
                var g = (function() {
                    function t() {}
                    return (
                        (t.prototype.clear = function() {
                            (this.title = null),
                            (this.content = null),
                            (this.type = null),
                            (this.data = null),
                            (this.confirmLabel = null),
                            (this.cancelLabel = null),
                            (this.confirm = null),
                            (this.cancel = null);
                        }),
                        (t.prototype.destroy = function() {
                            this.clear();
                        }),
                        t
                    );
                })();
                o.AlertVO = g;
                var _ = (function(t) {
                    function e() {
                        return (null !== t && t.apply(this, arguments)) || this;
                    }
                    return (
                        i(e, t),
                        (e.prototype.onInit = function() {
                            t.prototype.onInit.call(this),
                                (this._anim = this.view.getComponent(cc.Animation)),
                                (this._root = this.view.getChildByName('root')),
                                (this._txtTitle = h.default.getComponent(
                                    cc.Label,
                                    this._root,
                                    'txtTitle'
                                )),
                                (this._txtContent = h.default.getComponent(
                                    cc.Label,
                                    this._root,
                                    'txtContent'
                                )),
                                (this._btnConfirm = h.default.getNode(
                                    this._root,
                                    'bottom/btnConfirm'
                                )),
                                (this._btnConfirmLabel = h.default.getComponent(
                                    cc.Label,
                                    this._btnConfirm,
                                    'Background/txtLabel'
                                )),
                                this._btnConfirm.on(
                                    cc.Node.EventType.TOUCH_END,
                                    this.onTouchConfirm,
                                    this
                                ),
                                (this._btnCancel = h.default.getNode(
                                    this._root,
                                    'bottom/btnCancel'
                                )),
                                (this._btnCancelLabel = h.default.getComponent(
                                    cc.Label,
                                    this._btnCancel,
                                    'Background/txtLabel'
                                )),
                                this._btnCancel.on(
                                    cc.Node.EventType.TOUCH_END,
                                    this.onTouchCancel,
                                    this
                                );
                        }),
                        (e.prototype.onShow = function() {
                            t.prototype.onShow.call(this), this._anim.play('DefShowView');
                            var e = this.getData();
                            if (e)
                                switch (
                                    (e.title ?
                                        ((this._txtTitle.string = e.title),
                                            (this._txtTitle.node.parent = this._root)) :
                                        (this._txtTitle.node.parent = null),
                                        e.confirmLabel ?
                                        (this._btnConfirmLabel.string = e.confirmLabel) :
                                        (this._btnConfirmLabel.string = '确定'),
                                        e.cancelLabel ?
                                        (this._btnCancelLabel.string = e.cancelLabel) :
                                        (this._btnCancelLabel.string = '取消'),
                                        (this._txtContent.string = e.content),
                                        e.type)
                                ) {
                                    case a.Confirm:
                                        (this._btnConfirm.active = !0),
                                        (this._btnCancel.active = !1),
                                        (this._btnConfirm.x = 0);
                                        break;

                                    case a.Cancel:
                                        (this._btnConfirm.active = !1),
                                        (this._btnCancel.active = !0),
                                        (this._btnCancel.x = 0);
                                        break;

                                    default:
                                        (this._btnConfirm.active = !0),
                                        (this._btnCancel.active = !0),
                                        (this._btnConfirm.x = -0.175 * this._root.width),
                                        (this._btnCancel.x = 0.175 * this._root.width);
                                }
                        }),
                        (e.prototype.onTouchConfirm = function() {
                            var t = this.getData();
                            ((t && t.type == a.Confirm) || t.type == a.ConfirmAndCancel) &&
                            t.confirm &&
                                t.confirm(t.data),
                                u.SoundMrg.click(),
                                p.UIMrg.close(this);
                        }),
                        (e.prototype.onTouchCancel = function() {
                            var t = this.getData();
                            ((t && t.type == a.Cancel) || t.type == a.ConfirmAndCancel) &&
                            t.cancel &&
                                t.cancel(t.data),
                                u.SoundMrg.click(),
                                p.UIMrg.close(this);
                        }),
                        (e.RES = new c.UIViewRes('AlertView', 'Tips', l.UILayer.TipsLayer)),
                        r([d('AlertPanel')], e)
                    );
                })(s.default);
                (o.AlertPanel = _), console.log("end");
            module.exports =  e.exports;